package com.qqt.csr.common.enums;

import lombok.Getter;

@Getter
public enum YesOrNotEnum {

	NOT(0, "否"), YES(1, "是");

	private int value;
	private String message;

	YesOrNotEnum(int value, String message) {
		this.value = value;
		this.message = message;
	}

	public static YesOrNotEnum of(int value) {
		for (YesOrNotEnum item : values()) {
			if (item.value == value) {
				return item;
			}
		}
		return NOT;
	}
}
